package com.qunar.wan.common_api.service;


import com.qunar.wan.common_api.model.EmailTask;
import com.qunar.wan.common_api.model.enums.EmailType;
import com.qunar.wan.common_api.service.mapper.EmailTaskMapper;

import java.util.List;

/**
 * User: devry Date: 12/18/13 Time: 11:31 AM
 */
public interface EmailService extends BaseService<EmailTask, EmailTaskMapper> {
    /**
     * 批量插入邮件发送任务
     *
     * @param emailType
     * @param actId
     * @param userEmails
     */
    void send(EmailType emailType, int actId, List<String> userEmails);

    /**
     * 插入邮件发送任务
     *
     * @param emailType
     * @param actId
     * @param userEmail
     */
    void send(EmailType emailType, int actId, String userEmail);

    /**
     * 获取所有的邮件发送任务
     *
     * @return
     */
    List<EmailTask> selectEmailTask();

    /**
     * 删除已发送的邮件
     *
     * @param taskId
     * @param taskId
     */
    void deleteEmailTask(int taskId);

}
